﻿using CardPlay.Model.CardModel;
using CardPlay.Model.GameModel;
using CardPlay.Model.Layout;

namespace CardPlay.DemoPack.Games.KlondikeVariants
{
    [Game("DEEEE47C-6E8D-4CE2-ABF5-1A876921B6E4", LevelOfDifficulty.Medium, LevelOfSkill.MostlySkill, DurationOfPlay.Within5To10Minutes, Family = FamilyName)]
    public class Canister : Klondike
    {
        public Canister()
        {
            NamesOfAdditionalPiles.Clear();
            TotalTableaus = 8;
            TableauBuildSequence = CardFaceSequence.AlternatingColorAdjacentRank;
            FoundationRowAlignment = HorizontalAlignment.Center;
        }

        protected override void PrepareDealScript(DealScript script)
        {
            for (var i = 1; i <= TotalTableaus; ++i)
            {
                var count = (i > 2 && i < 7) ? 7 : 6;
                script.Deal(count + " up").To(StandardPileNames.PrefixForTableau + i);
            }
        }
    }
}